from time import sleep
from page.BASE_PAGE import BasePage
class HUADONG(BasePage):
    #向上滑动
    def swipe_up(self):
        self.driver.swipe(450,1400,450,200,500)
    #向下滑动
    def swipe_down(self):
        self.driver.swipe(450,200,450,1400,500)
    #向左滑动
    def swipe_left(self):
        self.driver.swipe(800,800,100,800,500)
    #向右滑动
    def swipe_right(self):
        self.driver.swipe(100,800,800,800,500)

    #上下左右滑动
    def swipe_udlr(self):
        self.driver.swipe(450, 1400, 450, 200, 500)
        sleep(2)
        self.driver.swipe(450, 200, 450, 1400, 500)
        sleep(2)
        self.driver.swipe(800, 800, 100, 800, 500)
        sleep(2)
        self.driver.swipe(100, 800, 800, 800, 500)
        sleep(2)